package com.ztesoft.web.common.customdb.dao.dto;

import java.util.Date;

import org.apache.commons.lang.StringUtils;

import com.ztesoft.framework.dto.AbstractDto;

public class DbLinkInstanceDto extends AbstractDto{
	private Integer  dbLinkId;
	private Integer  dbBaseId;
	private String  dbLinkName;
	private String  dbLinkMethod;
	private String  dbLinkBody;
	private String  dbLinkDesc;
	private String  state;
	private Date  stateDate;
	
    public Integer getDbLinkId() {
		return dbLinkId;
	}
	public void setDbLinkId(Integer dbLinkId) {
		this.dbLinkId = dbLinkId;
	}
	public Integer getDbBaseId() {
		return dbBaseId;
	}
	public void setDbBaseId(Integer dbBaseId) {
		this.dbBaseId = dbBaseId;
	}
	public String getDbLinkName() {
        return StringUtils.isBlank(dbLinkName) ? dbLinkName : dbLinkName.trim();
    }
    public void setDbLinkName(String dbLinkName) {
        this.dbLinkName = dbLinkName;
    }
    
    
    public String getDbLinkMethod() {
        return StringUtils.isBlank(dbLinkMethod) ? dbLinkMethod : dbLinkMethod.trim();
    }
    public void setDbLinkMethod(String dbLinkMethod) {
        this.dbLinkMethod = dbLinkMethod;
    }
    
    
    public String getDbLinkBody() {
        return StringUtils.isBlank(dbLinkBody) ? dbLinkBody : dbLinkBody.trim();
    }
    public void setDbLinkBody(String dbLinkBody) {
        this.dbLinkBody = dbLinkBody;
    }
    
    public String getDbLinkDesc() {
        return StringUtils.isBlank(dbLinkDesc) ? dbLinkDesc : dbLinkDesc.trim();
    }
    public void setDbLinkDesc(String dbLinkDesc) {
        this.dbLinkDesc = dbLinkDesc;
    }
    
    
    public String getState() {
        return StringUtils.isBlank(state) ? state : state.trim();
    }
    public void setState(String state) {
        this.state = state;
    }

	public Date getStateDate() {
		if (this.stateDate != null) 
			return (Date) stateDate.clone();
		return null;
	}

	public void setStateDate(Date stateDate) {
		if (stateDate == null) {
			this.stateDate = null;
		} else {			
			this.stateDate = (Date)stateDate.clone();
		}
	}
    
    
}